import pickle
score = {'张三':98,'李四':90,'王五':100}
with open('score.dat', 'wb') as fp:
    pickle.dump(score, fp)
with open('score.dat','rb') as fp:
    result = pickle.load(fp)
print(result)